<#--
***************************************************************************************
* 正元协同办公系统J2EE版
* 声明：金华正元计算机工程有限公司版权所有,
* 名称：wfReplyForm.ftl
* 功能：[回复信息] 编辑页面
* 来源：本页由wfReplyAction!detail.shtml跳转过来。
* 去向：
*    本页可以跳转到wfReceiptAction!list.ftl
*修改日志：
*			修改者及修改内容简述。
*			姓名：系统        时间：2008-10-24  内容：生成本页面
****************************************************************************************
-->

<#include "/common/pager_style/commonForm.ftl" encoding="UTF-8">
<#-- 定义有哪些按钮 reset:重写 back:返回 -->
<#--<#if editState="modify">
	<#assign buttonsName = {"save":"提交","reset":"重置","back":"返回"}>
<#else>
	<#assign buttonsName = {"back":"返回"}>
</#if>-->
<script language="JavaScript">
<!--
var actName="weekReviewAction";
var domainName="weekReview";

function checkForm(){
    var strMsg = "";
    var l = 0;
    if(typeof($("#weekReview\\.applyReason").val())=="string"){
    	  l = $("#weekReview\\.applyReason").val().length;
    }
    if(l>500){
    	alert("申请理由不能超过500个字符！");
    	return false;
    }
    if(l==0){
    	strMsg = "申请理由不能为空";
    	return false;
    }
    if(weekReview.applyType==1){
    	if($("#weekReview\\.delayDate").val()=="" || $("#weekReview\\.delayDate").val() == null){
	    	strMsg = "申请延期时间不能为空";
	    	return false;
	    }
    }
	//类型：AlphaNumeric,Date,Email,Empty,Numeric,Money,PostalCode,Url
	if( strMsg != "" )
	{
		alert( strMsg );
		return false;
	}
	return true;
}

	function openCo(){
		openReference('WeekForm','reviewTree','weekReview.reviewBy.id=value_id&weekReview.reviewBy.userName=value_name&dataType=value_dataType');
	}

-->
</script>
<style>
.all {
	height : 900px;
}
</style>
</head>
<body class="frameForm">
<form name="form1" action="" method="post" onsubmit="return checkForm();">
	<input type="hidden" id="weekRecord.id" name="weekRecord.id" value="${(weekRecord.id)?if_exists}"/>
	<input type="hidden" id="weekReview.id" name="weekReview.id" value="${(weekReview.id)?if_exists}"/>
	<input type="hidden" id="reviewOpenDate" name="reviewOpenDate" value="${(reviewOpenDate)?if_exists}"/>
	<input type="hidden" id="weekReview.applyType" name="weekReview.applyType" value="${(weekReview.applyType)?if_exists}"/>
	<div class="">
	<div class="ui-formfield all">
	<table class="tbl">
		<caption>审核申请</caption>
		<tbody>
			<!-- 数据录入 -->
			<tr>
				<td width="15%"></td>
				<td width="35%"></td>
				<td width="15%"></td>
				<td width="35%"></td>
			</tr>
			<#if weekReview.applyType??&& weekReview.applyType=1>		
				<@pEdit.pageEditText
		    		label="审核类型"
					pageState="${editState}"
					cssStyle=" width:140px;"
					inputReadOnly="true"
					attName="applyTypeStr"
					attValue="申请延期"
					colSpanNum="3"
					/>
			<#elseif  weekReview.applyType??&& weekReview.applyType=2>
				<@pEdit.pageEditText
		    		label="审核类型"
					pageState="${editState}"
					cssStyle=" width:140px;"
					inputReadOnly="true"
					attName="applyTypeStr"
					attValue="申请拒办"
					colSpanNum="3"
					/>
			<#elseif  weekReview.applyType??&& weekReview.applyType==3>
				<@pEdit.pageEditText
		    		label="审核类型"
					pageState="${editState}"
					cssStyle=" width:140px;"
					inputReadOnly="true"
					attName="applyTypeStr"
					attValue="申请重办"
					colSpanNum="3"
					/>
			<#elseif  weekReview.applyType??&& weekReview.applyType==5>
				<@pEdit.pageEditText
		    		label="审核类型"
					pageState="${editState}"
					cssStyle=" width:140px;"
					inputReadOnly="true"
					attName="applyTypeStr"
					attValue="申请退文"
					colSpanNum="3"
					/>
			</#if>	
			<#if showChoose?? && showChoose="yes">		
				<tr height="10px">
					<th>
						<label for="weekReview.reviewBy.id">审核人*<a href="#" onClick="openReference('SysUser', 'showEditDeptUserTreeAll', 'weekReview.reviewBy.userName=value2&weekReview.reviewBy.id=value1');return false;" title="点击指定人员范围"> >></a></label><br>
					</th>
					<td height="10px"   >
					<textarea name="weekReview.reviewBy.userName" class="" id="weekReview.reviewBy.userName"   onClick="openReference('SysUser', 'showEditDeptUserTreeAll', 'weekReview.reviewBy.userName=value2&weekReview.reviewBy.id=value1');return false;" style = "width:145px;height:20px;line-height:20px;" readonly  >${(weekReview.reviewBy.userName)?if_exists}</textarea>
					<input type="hidden" name="weekReview.reviewBy.id" id="weekReview.reviewBy.id" value="${(weekReview.reviewBy.id)?if_exists}">
					</td>
				</tr>
			<#else>
				<@pEdit.pageEditText
					label="审核人"
					pageState="${editState}"
					cssStyle=" width:140px;"
					inputReadOnly="true"
					attName="weekReview.reviewBy.userName"
					attValue="${(weekReview.reviewBy.userName)?if_exists}"
					colSpanNum="3"
					/>			
				<input type="hidden" id="weekReview.reviewBy.id" name="weekReview.reviewBy.id" value="${(weekReview.reviewBy.id)?if_exists}">
			</#if>
			<#-- 延期审核，需要选择延期时间，7天15天 -->
			<#if weekReview.applyType??&& weekReview.applyType==1>		
				<@pEdit.pageEditSelectUserValue
		    		label="延期时间"
		    		TR="false"
		    		cssStyle=" width:145px;"
			 		pageState="${editState}"
			  		attName="weekReview.delayDate"
			  		attValue="${(weekReview.delayDate)?if_exists}"
					optionSource={"7":"7天","15":"15天"}
					defaultValue="1"
					colSpanNum="3"/>
			</#if>								
			<@pEdit.pageEditTextarea
					beginTR = "true"
					endTR = "true"
					label="申请理由"
					height="40"
					cssStyle="height:70px; width:98%"
					pageState="${editState}"
					attName="weekReview.applyReason"
					attValue="${(weekReview.applyReason)?if_exists}"
					colSpanNum="3"/>
		</tbody>
	</table><!-- 数据录入结束 -->
	</div><!-- end #ui-formfield -->
	</div><!-- end #ui-com-main -->
</form>
</body>
</html>